<?php

namespace app\admin\validate;

class SystemRoleValidate extends BaseValidate
{
    /**
     * 定义验证规则
     * 格式：'字段名'	=>	['规则1','规则2'...]
     *
     * @var array
     */	
	protected $rule = [
        'role_name' => 'require|length:2,10',
        'status' => 'require|min:1',
        'rules' => 'require',
    ];

    protected $message  =   [
        'role_name.require' => '身份名称不能为空',
        'role_name.length' => '身份名称长度在2 到 10 个字符之间',
        'status.require' => '请选择开启状态',
        'status.min' => '开启状态不能格式不正确',
        'rules.require' => '请选择权限'
    ];
}